
export const IMG_FILTER_TYPES = [
  { name:'模糊', value:'blur',  },
  { name:'灰度', value:'grey',  },
  { name:'颜色', value:'color',  },
  { name:'遮罩', value:'mask',  },

]
export const SHAPE_STYLES = [
  { name:'线', value:'line', },
  { name:'弧线', value:'arc' },
  // { name:'贝兹曲线', value:'quadratic' },
  { name:'矩形', value:'rect' },
  { name:'圆角矩形', value:'roundRect' },
  { name:'圆形', value:'circle' },
  { name:'椭圆', value:'ellipse' },
  { name:'五角星形', value:'polyStar' },
  // { name:'圆角复杂图形', value:'roundRectComplex' },
]
//bitmap-text
export const BITMAP_TEXT_ITEM_TYPES = [
  { name:'文本', value: 0 },
  { name:'日历', value: 1},
]
export const BITMAP_TEXT_ITEM_TYPES_MAP = {
  text: 0,
  date: 1,
}

export const MASK_SHAPE_STYLES = [
  { name:'圆角矩形', value:'roundRect' },
  { name:'圆形', value:'circle' },
  { name:'椭圆', value:'ellipse' },
]

export const SHAPE_STYLE_TYPE = {
  line: { name: 'line', commonds: ['lineTo']},
  arc: { name: 'arc', commonds: ['arcTo'] },
  // quadratic: { name: 'quadratic', commonds: ['quadraticCurveTo'] },
  rect: { name: 'rect', commonds: ['rect'] },
  roundRect: { name: 'roundRect', commonds: ['drawRoundRect'] },
  circle: { name: 'circle', commonds: ['drawCircle'] },
  ellipse: { name: 'ellipse', commonds: ['drawEllipse'] },
  polyStar: { name: 'polyStar', commonds: ['drawPolyStar'] },
  roundRectComplex: { name: 'roundRectComplex', commonds: ['drawRoundRectComplex'] },
}

export const SHAPE_FILL_STYLES = [
  { name:'颜色填充', value:'color' },
  { name:'渐变填充', value:'gradient' },
  { name:'位图填充', value:'bitmap' },
]

export const SHAPE_STROKE_STYLES = [
  { name:'颜色填充', value:'color' },
  { name:'渐变填充', value:'gradient' },
  { name:'虚线填充', value:'dash' },
]
//[0, 1], 5, 0, 110, 0)//[0, 1], 0, 0, 0, 130上下渐变 [0, 1], 40, 40, 0, 40, 40, 40圆形渐变
export const GRADIENT_DIRECTION = [
  { name:'左右渐变', value: 1},
  { name:'上下渐变', value: 2},
  { name:'圆形渐变', value: 3},
]
export const GRADIENT_DIRECTION_VALUE = {
  1: [[0, 1], 5, 0, 110, 0],
  2: [[0, 1], 0, 0, 0, 130],
  3: [[0, 1], 40, 40, 0, 40, 40, 40],
}
export const SHAPE_STROKE_TYPE = {
  color: { name: 'color', comps: ['color-normal'] },
  gradient: { name: 'gradient', commonds: ['beginLinearGradientStroke']},
  dash: { name: 'dash', commonds: ['setStrokeDash']},

}
export const SHAPE_FILL_TYPE = {
  color: { name: 'color', comps: ['color-normal'] },
  gradient: { name: 'gradient', commonds: ['beginLinearGradientStroke']},
  bitmap: { name: 'bitmap', comps: ['add-img-con'], commonds: ['beginBitmapFill']},

}
//数组下标
export const CANVAS_BG_MC_TYPES = [
  { name: '心形背景动画', value: 0},
  { name: '星空月亮动画', value: 1},
  { name: '点击圆形动画', value: 2},
]
export const PIXI_SPRITE_ANIMATES = [
  { name:"飞机动画", value:"fighter" },
  { name:"爆炸动画", value:"explode" },
  { name:"数字动画", value:"number" },
]
export const PIXI_SPRITE_ANIMATES_MAP = {
  "fighter": { 
    defaultPicUrl: "https://static.hd.xxx.com/upload/biz/assets/pixi/texturepacker/demos/particles/Fighter-0.png", 
    jsonUrl: "https://static.hd.xxx.com/upload/biz/assets/pixi/texturepacker/demos/particles/Fighter.json",
    itemType: "fighter",
  },
  "explode": { 
    defaultPicUrl: "https://static.hd.xxx.com/upload/biz/assets/pixi/texturepacker/demos/particles/Explode-0.png", 
    jsonUrl: "https://static.hd.xxx.com/upload/biz/assets/pixi/texturepacker/demos/particles/Explode.json",
    itemType: "explode",
  },
  "number": { 
    defaultPicUrl: "https://static.hd.xxx.com/upload/biz/assets/pixi/texturepacker/demos/particles/Number-0.png", 
    jsonUrl: "https://static.hd.xxx.com/upload/biz/assets/pixi/texturepacker/demos/particles/Number.json",
    itemType: "number",
  },
}
export const CANVAS_BG_MC_TYPES_MAP = {
  heart: 0,
  moon: 1,
  clickCircle: 2,
}
export const CANVAS_MC_TYPES = [
  // { name: '大象动画', value: 0 },
  // { name: '拖拽装修', value: 1 },
  // { name: '开门动画', value: 2 },
  // { name: 'mac商品1', value: 3 },
  // { name: 'mac商品2', value: 4 },
  // { name: 'mac商品3', value: 5 },
  // { name: 'mac商品4', value: 6 },
  // { name: '展开三角动画', value: 7 },
  { name: '动画', value: 0 },
  // { name: '足球', value: 1 },
  // { name: '京东七夕', value: 8 },
  { name: '美食地图', value: 9 },
  { name: '自定义', value: 101 },
]

export const CREATEJS_CONSTS = {
  "0": {type: "mc", x: 0, y: 0, id: "EB16422FE7F54516A47CF6317F053D14", className: "VideoAnimate"},
  // "1": {type: "Football", x: 0, y: 0, id: "66F3283332C4460CBEC33A387212B713", className: "Football"},
  // "1": {type: "DragFurniture", x: 0, y: 0, id: "33C6AF66DA0946AEA213001E0F661081", className: "DragFurniture", isVector: false},
  // "2": {type: "mc", x: 0, y: 0, id: "944BBB847A6C41C481E3ED2C925796F7", className: "MacOpenDoor", isVector: false},
  // "3": {type: "mc", x: 0, y: 0, id: "C443E09900DC49C6AF1D353FEE69FDAA", className: "MacShopOne", isVector: false},
  // "4": {type: "mc", x: 0, y: 0, id: "930ADE46F8B84F718DCC062B40158B3E", className: "MacShopTwo", isVector: false},
  // "5": {type: "mc", x: 0, y: 0, id: "5AD0F64475F8449FA312A45F18C2AF75", className: "MacShopThree", isVector: false},
  // "6": {type: "mc", x: 0, y: 0, id: "757AC1FF5B644E98A905A43173A8C550", className: "MacShopFour", isVector: false},
  // "7": {type: "mc", x: 0, y: 0, id: "C2A4ED342C6A43A28540DB15CCD65F9A", className: "UnfoldTriangleAnimate", isVector: false},
  // "8": {type: "JdQixiFestival", x: 0, y: 0, id: "E1460967B70C445D836752536FA05F2B", className: "JdQixiFestival"},
  "9": {type: "FoodMap", x: 0, y: 0, id: "1D308DC164924FB3B41E39BD289E9987", className: "FoodMap"},
}
//1228 非人哉拼图 1229 点亮美食地图 1149 京东黑话

export const CREATEJS_CONSTS_MAP = {
  mc: 'mc',
  // football: 'Football',
  // elephantMC: 'ElephantMC',
  // dragFurniture: 'DragFurniture',
  // jdQixiFestival: 'JdQixiFestival',
  foodMap: 'FoodMap',
}

export const CANVAS_MC_TYPES_MAP = {
  foodMap: 9,
  custom: 101,
}
export const  CANVAS_MC_CLASSNAME_TYPES = [
  { name: '点击消失', value: 'ClickDisappear' },
  // { name: '滑动拉链', value: 'SlideZipper' },
  { name: '逐帧动画', value: 'FrameAnim' },
]

export const  CANVAS_MC_CLASSNAME_TYPES_MAP = {
  ClickDisappear: 'ClickDisappear',
  // SlideZipper: 'SlideZipper',
  FrameAnim: 'FrameAnim',
}


export const THREE_LOAD_TYPES = [
  { name: "gltf格式", value: "gltf" },
]

export const RESIZE_TYPE = [
  { name:'拉伸', value: 3},
  { name:'等比最小', value: 1},
  { name:'等比最大', value: 2},
]

export const RESIZE_TYPE_MAP = {
  min: 1,
  max: 2,
  stretch: 3,
}
/* ---------------------pixi------------------ */
export const PIXI_MC_TYPES = [
  { name: '展开三角动画', value: 0 },
]
export const PIXI_ANIMATE_TYPE = [
  { name:'屏幕中随机游走', value: 0 },
]
//SpawnType Point Rectangle Circle Ring Burst
export const PIXI_PARTICAL_BLENDMODE = [
  { name:"正常", value:"normal" },
  { name:"增强", value:"add" },
  { name:"正片叠底", value:"multiply" },
  { name:"滤色", value:"screen" },
  { name:"叠加(canvas only)", value:"overlay" },
  { name:"变暗(canvas only)", value:"darken" },
  { name:"变淡(canvas only)", value:"lighten" },
  { name:"颜色减淡(canvas only)", value:"color_dodge" },
  { name:"颜色加深(canvas only)", value:"color_burn" },
  { name:"强光(canvas only)", value:"hard_light" },
  { name:"柔光(canvas only)", value:"soft_light" },
  { name:"差值(canvas only)", value:"difference" },
  { name:"排除(canvas only)", value:"exclusion" },
  { name:"色相(canvas only)", value:"hue" },
  { name:"饱和度(canvas only)", value:"saturation" },
  { name:"颜色(canvas only)", value:"color" },
  { name:"明度(canvas only)", value:"luminosity" },
]
export const PIXI_FILTERS =  [
  { name: '无', value: '' },
  { name: 'Adjustment', value: 'AdjustmentFilter' },
  { name: 'AdvancedBloom', value: 'AdvancedBloomFilter' },
  { name: 'Alpha', value: 'AlphaFilter' },
  { name: 'Ascii', value: 'AsciiFilter' },
  { name: 'Bevel', value: 'BevelFilter' },
  { name: 'Bloom', value: 'BloomFilter' },
  { name: 'Blur', value: 'BlurFilter' },
  { name: 'BulgePinch', value: 'BulgePinchFilter' },
  { name: 'ColorMap', value: 'ColorMapFilter' },
  { name: 'ColorMatrix', value: 'ColorMatrixFilter' },
  { name: 'ColorOverlay', value: 'ColorOverlayFilter' },
  { name: 'ColorReplace', value: 'ColorReplaceFilter' },
  { name: 'Convolution', value: 'ConvolutionFilter' },
  { name: 'CrossHatch', value: 'CrossHatchFilter' },
  { name: 'CRT', value: 'CRTFilter' },
  { name: 'Displacement', value: 'DisplacementFilter' },
  { name: 'Dot', value: 'DotFilter' },
  { name: 'DropShadow', value: 'DropShadowFilter' },
  { name: 'Emboss', value: 'EmbossFilter' },
  // { name: 'Glitch', value: 'GlitchFilter' },
  { name: 'Glow', value: 'GlowFilter' },
  // { name: 'Godray', value: 'GodrayFilter' },
  { name: 'KawaseBlur', value: 'KawaseBlurFilter' },
  { name: 'Lightmap', value: 'LightmapFilter' },
  { name: 'MotionBlur', value: 'MotionBlurFilter' },
  // { name: 'MultiColorReplace', value: 'MultiColorReplaceFilter' },
  { name: 'Noise', value: 'NoiseFilter' },
  { name: 'OldFilm', value: 'OldFilmFilter' },
  { name: 'Outline', value: 'OutlineFilter' },
  { name: 'Pixelate', value: 'PixelateFilter' },
  { name: 'RadialBlur', value: 'RadialBlurFilter' },
  // { name: 'Reflection', value: 'ReflectionFilter' },
  { name: 'RGBSplit', value: 'RGBSplitFilter' },
  { name: 'Shockwave', value: 'ShockwaveFilter' },
  { name: 'TiltShift', value: 'TiltShiftFilter' },
  { name: 'Twist', value: 'TwistFilter' },
  { name: 'ZoomBlur', value: 'ZoomBlurFilter' },
]
const COLOR_MAP_URL = 'https://static.hd.xxx.com/upload/biz/assets/pixi/texturepacker/demos/filters/filter_colormap.png';
const FILTER_LIST = [{value:3,name:'3'},{value:5,name:'5'},{value:7,name:'7'},{value:9,name:'9'},{value:11,name:'11'},{value:13,name:'13'},{value:15,name:'15'},{value:17,name:'17'},{value:19,name:'19'},{value:21,name:'21'},{value:23,name:'23'},{value:25,name:'25'}]
// [3,5,7,9,11,13,15,17,19,21,23,25]
export const PIXI_FILTERS_MAP =  {
  AdjustmentFilter:{isAdjustment:false,type:'AdjustmentFilter',attrs:{gamma:{min:0,max:5,step:1,value:1,type:'SliderNormal'},saturation:{min:0,max:5,step:1,value:1,type:'SliderNormal'},contrast:{min:0,max:5,step:1,value:1,type:'SliderNormal'},brightness:{min:0,max:5,step:1,value:1,type:'SliderNormal'},red:{min:0,max:5,step:1,value:1,type:'SliderNormal'},green:{min:0,max:5,step:1,value:1,type:'SliderNormal'},blue:{min:0,max:5,step:1,value:1,type:'SliderNormal'},alpha:{min:0,max:1,step:0.1,value:1,type:'SliderNormal'}}},
  AdvancedBloomFilter:{isAdvancedBloom:false,type:'AdvancedBloomFilter',attrs:{threshold:{min:0.1,max:0.9,step:0.1,value:0.5,type:'SliderNormal'},bloomScale:{min:0.5,max:1.5,step:0.1,value:1,type:'SliderNormal'},brightness:{min:0.5,max:1.5,step:0.1,value:1,type:'SliderNormal'},blur:{min:0,max:20,step:1,value:8,type:'SliderNormal'},quality:{min:0,max:20,step:1,value:4,type:'SliderNormal'}}},
  AlphaFilter:{isAlpha:false,type:'AlphaFilter',attrs:{alpha:{min:0,max:1,step:0.1,value:1,type:'SliderNormal'}}},
  AsciiFilter:{isAscii:false,type:'AsciiFilter',attrs:{size:{min:2,max:20,step:1,value:8,type:'SliderNormal'}}},
  BevelFilter:{isBevel:false,type:'BevelFilter',attrs:{rotation:{min:0,max:360,step:1,value:45,type:'SliderNormal'},thickness:{min:0,max:5,step:1,value:2,type:'SliderNormal'},lightColor:{value:'0xfff',type:'ColorNormal'},lightAlpha:{min:0,max:1,step:0.1,value:0.7,type:'SliderNormal'},shadowColor:{value:'0x000',type:'ColorNormal'},shadowAlpha:{min:0,max:1,step:0.1,value:0.7,type:'SliderNormal'}}},
  BloomFilter:{isBloom:false,type:'BloomFilter',attrs:{blur:{min:0,max:20,step:1,value:2,type:'SliderNormal'},blurX:{min:0,max:20,step:1,value:2,type:'SliderNormal'},blurY:{min:0,max:20,step:1,value:2,type:'SliderNormal'}}},
  BlurFilter:{isBlur:false,type:'BlurFilter',attrs:{blur:{min:0,max:100,step:1,value:8,type:'SliderNormal'},quality:{min:1,max:10,step:1,value:4,type:'SliderNormal'}}},
  BulgePinchFilter:{isBulgePinch:false,type:'BulgePinchFilter',attrs:{radius:{min:0,max:1000,step:1,value:100,type:'SliderNormal'},strength:{min:-1,max:1,step:0.1,value:1,type:'SliderNormal'},center:{x:{min:0,max:1,step:0.1,value:0.5,type:'SliderNormal'},y:{min:0,max:1,step:0.1,value:0.5,type:'SliderNormal'}}}},
  ColorMapFilter:{isColorMap:false,type:'ColorMapFilter',args:['colorMap',false],attrs:{mix:{min:0,max:1,step:0.1,value:0.4,type:'SliderNormal'},nearest:{value:false,type:'SwitchNormal'},url:{type:'AddImgCon',value:COLOR_MAP_URL}}},
  ColorMatrixFilter:{isColorMatrix:false,type:'ColorMatrixFilter',attrs:{reset:{value:false,type:'SwitchNormal'},sepia:{value:false,type:'SwitchNormal'},negative:{value:false,type:'SwitchNormal'},kodachrome:{value:false,type:'SwitchNormal'},lsd:{value:false,type:'SwitchNormal'},polaroid:{value:false,type:'SwitchNormal'},desaturate:{value:false,type:'SwitchNormal'},contrast:{value:false,type:'SwitchNormal'},greyscale:{value:false,type:'SwitchNormal'},predator:{value:false,type:'SwitchNormal'},saturate:{value:false,type:'SwitchNormal'}}},
  ColorOverlayFilter:{isColorOverlay:false,type:'ColorOverlayFilter',args:[0xff0000],attrs:{color:{value:'0xff0000',type:'ColorNormal'}}},
  ColorReplaceFilter:{isColorReplace:false,type:'ColorReplaceFilter',attrs:{originalColor:{value:'0xff0000',type:'ColorNormal'},newColor:{value:'0x000',type:'ColorNormal'},epsilon:{min:0,max:1,step:0.1,value:0.4,type:'SliderNormal'}}},
  ConvolutionFilter:{isConvolution:false,type:'ConvolutionFilter',args:[[0,0.5,0,0.5,1,0.5,0,0.5,0],300,300],attrs:{matrixs:[{min:0,max:1,step:0.1,value:0},{min:0,max:1,step:0.1,value:0.5},{min:0,max:1,step:0.1,value:0,type:'SliderNormal'},{min:0,max:1,step:0.1,value:0.5,type:'SliderNormal'},{min:0,max:1,step:0.1,value:1,type:'SliderNormal'},{min:0,max:1,step:0.1,value:0.5,type:'SliderNormal'},{min:0,max:1,step:0.1,value:0,type:'SliderNormal'},{min:0,max:1,step:0.1,value:0.5,type:'SliderNormal'},{min:0,max:1,step:0.1,value:0,type:'SliderNormal'}],width:{value:300,type:'InputNormal'},height:{value:300,type:'InputNormal'}}},
  CrossHatchFilter:{isCrossHatch:false,type:'CrossHatchFilter',attrs:{}},
  CRTFilter:{isCRT:false,type:'CRTFilter',args:[{lineWidth:3,lineContrast:0.3,noise:0.2,time:0.5,}],attrs:{animating:{value:true,type:'SwitchNormal'},curvature:{min:0,max:10,step:1,value:1,type:'SliderNormal'},lineWidth:{min:0,max:5,step:0.1,value:3,type:'SliderNormal'},lineContrast:{min:0,max:1,step:0.1,value:0.3,type:'SliderNormal'},verticalLine:{value:false,type:'SwitchNormal'},noise:{min:0,max:1,step:0.1,value:0.2,type:'SliderNormal'},noiseSize:{min:1,max:10,step:1,value:2,type:'SliderNormal'},vignetting:{min:0,max:1,step:0.1,value:0.3,type:'SliderNormal'},vignettingAlpha:{min:0,max:1,step:0.1,value:1,type:'SliderNormal'},vignettingBlur:{min:0,max:1,step:0.1,value:0.3,type:'SliderNormal'},seed:{min:0,max:1,step:0.1,value:0,type:'SliderNormal'},time:{min:0,max:20,step:1,value:0.5,type:'SliderNormal'}}},
  DisplacementFilter:{isDisplacement:false,type:'DisplacementFilter',args:['displacementSprite','width','height'],attrs:{scale:{x:{min:1,max:200,step:1,value:50,type:'SliderNormal'},y:{min:1,max:200,step:1,value:50,type:'SliderNormal'}}}},
  DotFilter:{isDot:false,type:'DotFilter',attrs:{scale:{min:0.3,max:1,step:0.1,value:1,type:'SliderNormal'},angle:{min:0,max:5,step:1,value:5,type:'SliderNormal'}}},
  DropShadowFilter:{isDropShadow:false,type:'DropShadowFilter',attrs:{blur:{min:0,max:20,step:1,value:2,type:'SliderNormal'},quality:{min:0,max:20,step:1,value:3,type:'SliderNormal'},alpha:{min:0,max:1,step:0.1,value:0.5,type:'SliderNormal'},distance:{min:0,max:50,step:1,value:5,type:'SliderNormal'},rotation:{min:0,max:360,step:1,value:45,type:'SliderNormal'},color:{value:'0x000',type:'ColorNormal'},shadowOnly:{value:false,type:'SwitchNormal'}}},
  EmbossFilter:{isEmboss:false,type:'EmbossFilter',attrs:{strength:{min:0,max:20,step:1,value:5,type:'SliderNormal'}}},
  // GlitchFilter:{isGlitch:false,type:'GlitchFilter',values:[],attrs:{color:''}},
  GlowFilter:{isGlow:false,type:'GlowFilter',args:[15,2,1,0xffffff,0.1],attrs:{innerStrength:{min:0,max:20,step:1,value:1,type:'SliderNormal'},outerStrength:{min:0,max:20,step:1,value:2,type:'SliderNormal'},distance:{min:10,max:20,step:1,value:15,type:'SliderNormal'},color:{value:'0xfff',type:'ColorNormal'}}},
  // GodrayFilter:{isGodray:false,type:'GodrayFilter',values:[],attrs:{color:''}},
  KawaseBlurFilter:{isKawaseBlur:false,type:'KawaseBlurFilter',args:[4,3,true],attrs:{blur:{min:0,max:20,step:1,value:4,type:'SliderNormal'},quality:{min:0,max:20,step:1,value:3,type:'SliderNormal'},pixelSize:{x:{min:0,max:10,step:1,value:1,type:'SliderNormal'},y:{min:0,max:10,step:1,value:1,type:'SliderNormal'}}}},
  
  LightmapFilter:{isLightmap:false,type:'LightmapFilter',args:['lightmap.texture','0x666666'],attrs:{color:{value:'0x666666',type:'ColorNormal'},alpha:{min:0,max:1,step:0.1,value:1,type:'SliderNormal'}}},
  MotionBlurFilter:{isMotionBlur:false,type:'MotionBlurFilter',args:[[40,40],15],attrs:{velocity:{x:{min:-90,max:90,step:1,value:40,type:'SliderNormal'},y:{min:-90,max:90,step:1,value:40,type:'SliderNormal'}},kernelSize:{value:15,list:FILTER_LIST,type:'DropdownNormal'},offset:{min:-150,max:150,step:1,value:0,type:'SliderNormal'}}},
  // MultiColorReplaceFilter:{isMultiColorReplace:false,type:'MultiColorReplaceFilter',values:[],attrs:{color:''}},
  NoiseFilter:{isNoise:false,type:'NoiseFilter',attrs:{noise:{min:0,max:1,step:0.1,value:0.5,type:'SliderNormal'},seed:{min:0.01,max:0.99,step:0.01,value:0.27,type:'SliderNormal'}}},
  OldFilmFilter:{isOldFilm:false,type:'OldFilmFilter',args:[['width/2','height/2']],attrs:{sepia:{min:0,max:1,step:0.1,value:0.3,type:'SliderNormal'},noise:{min:0,max:1,step:0.1,value:0.3,type:'SliderNormal'},noiseSize:{min:0,max:1,step:0.1,value:1,type:'SliderNormal'},cratch:{min:0,max:1,step:0.1,value:0.5,type:'SliderNormal'},scratchDensity:{min:0,max:1,step:0.1,value:0.3,type:'SliderNormal'},scratchWidth:{min:0,max:1,step:0.1,value:1,type:'SliderNormal'},ignetting:{min:0,max:1,step:0.1,value:0.3,type:'SliderNormal'},ignettingAlpha:{min:0,max:1,step:0.1,value:1,type:'SliderNormal'},ignettingBlur:{min:0,max:1,step:0.1,value:0.3,type:'SliderNormal'}}},
  OutlineFilter:{isOutline:false,type:'OutlineFilter',args:[4,0x000,0.25],attrs:{thickness:{min:0,max:10,step:1,value:4,type:'SliderNormal'},color:{value:'0x000',type:'ColorNormal'}}},
  PixelateFilter:{isPixelate:false,type:'PixelateFilter',attrs:{size:{x:{min:4,max:40,step:1,value:10,type:'SliderNormal'},y:{min:4,max:40,step:1,value:10,type:'SliderNormal'}}}},
  
  RadialBlurFilter:{isRadialBlur:false,type:'RadialBlurFilter',args:[20,['width/2','height/2'],15,300],attrs:{angle:[-180,180,1,20],center:{x:{min:0,max:'width',step:1,value:700,type:'SliderNormal'},y:{min:0,max:'height',step:1,value:383,type:'SliderNormal'}},radius:{min:0,max:"width",step:1,value:300,type:'SliderNormal'},kernelSize:{value:15,list:FILTER_LIST,type:'DropdownNormal'}}},
  // ReflectionFilter:{isReflection:false,type:'ReflectionFilter',values:[],attrs:{color:''}},
  RGBSplitFilter:{isRGBSplit:false,type:'RGBSplitFilter',attrs:{red:{x:{min:-20,max:20,step:1,value:-10,type:'SliderNormal'},y:{min:-20,max:20,step:1,value:0,type:'SliderNormal'}},blue:{x:{min:-20,max:20,step:1,value:0,type:'SliderNormal'},y:{min:-20,max:20,step:1,value:0,type:'SliderNormal'}},green:{x:{min:-20,max:20,step:1,value:0,type:'SliderNormal'},y:{min:-20,max:20,step:1,value:10,type:'SliderNormal'}}}},
  ShockwaveFilter:{isShockwave:false,type:'ShockwaveFilter',args:[['width/2','height/2']],attrs:{animating:{value:true,type:'SwitchNormal'},time:{min:0,max:10,step:0.1,value:0,type:'SliderNormal'},amplitude:{min:1,max:100,step:1,value:30,type:'SliderNormal'},wavelength:{min:2,max:100,step:1,value:160,type:'SliderNormal'},brightness:{min:0.2,max:2.0,step:0.1,value:1,type:'SliderNormal'},radius:{min:100,max:2000,step:1,value:-1,type:'SliderNormal'},center:{x:{min:0,max:'width',step:1,value:700,type:'SliderNormal'},y:{min:0,max:'height',step:1,value:383,type:'SliderNormal'}}}},
  TiltShiftFilter:{isTiltShift:false,type:'TiltShiftFilter',attrs:{blur:{min:0,max:200,step:1,value:100,type:'SliderNormal'},gradientBlur:{min:1,max:1000,step:1,value:600,type:'SliderNormal'}}},
  TwistFilter:{isTwist:false,type:'TwistFilter',attrs:{angle:{min:-10,max:10,step:1,value:4,type:'SliderNormal'},radius:{min:0,max:'width',step:1,value:200,type:'SliderNormal'},x:{min:0,max:'width',step:1,value:700,type:'SliderNormal'},y:{min:0,max:'height',step:1,value:383,type:'SliderNormal'}}},
  ZoomBlurFilter:{isZoomBlur:false,type:'ZoomBlurFilter',args:[0.1,['width/2','height/2'],80],attrs:{strength:{min:0.01,max:0.5,step:0.01,value:0.1,type:'SliderNormal'},center:{x:{min:0,max:'width',step:1,value:700,type:'SliderNormal'},y:{min:0,max:'height',step:1,value:383,type:'SliderNormal'}},innerRadius:{min:0,max:'width/2',step:1,value:80,type:'SliderNormal'}}},
}
//anim
export const PIXI_PARTICLES_TYPES = [
  { name: "气泡", value: 0, key: "bubbles", type: '', isSpritesheet: false },
  { name: "喷射气泡", value: 1, key: "bubbleSpray", type: '', isSpritesheet: false },
  { name: "冒气泡流（单一）", value: 2, key: "bubbleStream", type: '', isSpritesheet: false },
  { name: "路径冒气泡", value: 3, key: "bubbleStreamPath", type: 'path', isSpritesheet: false  },
  { name: "向上冒气泡（多）", value: 4, key: "bubbleVertical", type: '', isSpritesheet: false },
  { name: "泡泡动画", value: 5, key: "bubbleAnim", type: 'anim', isSpritesheet: true },
  { name: "雨", value: 6, key: "rain", type: '', isSpritesheet: false },
  { name: "雪", value: 7, key: "snow", type: '', isSpritesheet: false },
  { name: "光晕", value: 8, key: "gas", type: '', isSpritesheet: false },
]
export const PARTICLE_TYPE = {
  null: "",
  path: "path",
  anim: "anim"
}
export const PIXI_PARTICLES_TYPES_MAP = {
  bubbles: 0,
  bubbleSpray: 1,
  bubbleStream: 2,
  bubbleStreamPath: 3,
  bubbleVertical: 4,
  bubbleAnim: 5,
  rain: 6,
  snow: 7,
  gas: 8,
}
export const PIXI_PARTICLES_ANIM = {
  bubbleAnim: {
    spritesheet: "https://static.hd.xxx.com/upload/biz/assets/pixi/texturepacker/demos/particles/pop_anim.json",
    art: {
      framerate: "matchLife",
      textures: [
        {
          texture: "Bubbles99.png",
          count: 40,
        },
        {
          texture: "Pop1.png",
          count: 1,
        },
        {
          texture: "Pop2.png",
          count: 1,
        },
        {
          texture: "Pop3.png",
          count: 1,
        }
      ]
    }
  },
  rain: {
    art: {textures: [{url : "https://static.hd.xxx.com/upload/biz/assets/pixi/texturepacker/demos/particles/HardRain.png"}]}
  },
  snow: {
    art: {textures: [{url : "https://static.hd.xxx.com/upload/biz/assets/pixi/texturepacker/demos/particles/Snow.png"}]}
  },
  gas: {
    art: {textures: [
      {url : "https://static.hd.xxx.com/upload/biz/assets/pixi/texturepacker/demos/particles/Gas_0.png"},
      {url : "https://static.hd.xxx.com/upload/biz/assets/pixi/texturepacker/demos/particles/Gas_1.png"}
    ]}
  }
}
export const PIXI_PARTICLES = {
  bubbles: {
    "alpha": {
      "start": 1,
      "end": 0.22
    },
    "scale": {
      "start": 0.25,
      "end": 0.75,
      "minimumScaleMultiplier":0.5
    },
    "color": {
      "start": "ffffff",
      "end": "ffffff"
    },
    "speed": {
      "start": 200,
      "end": 50
    },
    "startRotation": {
      "min": 0,
      "max": 360
    },
    "rotationSpeed": {
      "min": 0,
      "max": 10
    },
    "lifetime": {
      "min": 4,
      "max": 4
    },
    "blendMode": "normal",
    "frequency": 0.016,
    "emitterLifetime": 0,
    "maxParticles": 500,
    "pos": {
      "x": 0,
      "y": 0
    },
    "addAtBack": false,
    "spawnType": "point"
  },
  bubbleSpray: {
    "alpha": {
      "start": 1,
      "end": 0.12
    },
    "scale": {
      "start": 0.01,
      "end": 0.8,
      "minimumScaleMultiplier":0.5
    },
    "color": {
      "start": "ffffff",
      "end": "ffffff"
    },
    "speed": {
      "start": 600,
      "end": 200
    },
    "startRotation": {
      "min": 260,
      "max": 280
    },
    "rotationSpeed": {
      "min": 0,
      "max": 10
    },
    "lifetime": {
      "min": 0.5,
      "max": 1
    },
    "blendMode": "normal",
    "frequency": 0.008,
    "emitterLifetime": 0.15,
    "maxParticles": 500,
    "pos": {
      "x": 0,
      "y": 0
    },
    "addAtBack": false,
    "spawnType": "point"
  },
  bubbleStream: {
    "alpha": {
      "start": 1,
      "end": 0.16
    },
    "scale": {
      "start": 0.3,
      "end": 0.6,
      "minimumScaleMultiplier":0.5
    },
    "color": {
      "start": "ffffff",
      "end": "ffffff"
    },
    "speed": {
      "start": 600,
      "end": 200
    },
    "startRotation": {
      "min": 267,
      "max": 273
    },
    "rotationSpeed": {
      "min": 0,
      "max": 20
    },
    "lifetime": {
      "min": 1.8,
      "max": 2
    },
    "blendMode": "normal",
    "frequency": 0.1,
    "emitterLifetime": 0,
    "maxParticles": 500,
    "pos": {
      "x": 0,
      "y": 0
    },
    "addAtBack": false,
    "spawnType": "point"
  },
  bubbleStreamPath: {
    "alpha": {
      "start": 1,
      "end": 0.16
    },
    "scale": {
      "start": 0.3,
      "end": 0.4,
      "minimumScaleMultiplier":0.5
    },
    "color": {
      "start": "ffffff",
      "end": "ffffff"
    },
    "speed": {
      "start": 150,
      "end": 100
    },
    "startRotation": {
      "min": 270,
      "max": 270
    },
    "rotationSpeed": {
      "min": 0,
      "max": 20
    },
    "lifetime": {
      "min": 1.8,
      "max": 2
    },
    "blendMode": "normal",
    "frequency": 0.1,
    "emitterLifetime": 0,
    "maxParticles": 500,
    "pos": {
      "x": 0,
      "y": 0
    },
    "addAtBack": false,
    "spawnType": "point",
    "extraData":
    {
      "path":"sin(x/10)*20"
    }
  },
  bubbleVertical: {
    "alpha": {
      "start": 1,
      "end": 0.22
    },
    "scale": {
      "start": 0.25,
      "end": 0.5,
      "minimumScaleMultiplier":0.5
    },
    "color": {
      "start": "ffffff",
      "end": "ffffff"
    },
    "speed": {
      "start": 200,
      "end": 200
    },
    "startRotation": {
      "min": 260,
      "max": 280
    },
    "rotationSpeed": {
      "min": 0,
      "max": 50
    },
    "lifetime": {
      "min": 3.5,
      "max": 4
    },
    "blendMode": "normal",
    "frequency": 0.016,
    "emitterLifetime": 0,
    "maxParticles": 500,
    "pos": {
      "x": 0,
      "y": 0
    },
    "addAtBack": false,
    "spawnType": "rect",
    "spawnRect": {
      "x": -450,
      "y": 200,
      "w": 900,
      "h": 0
    }
  },
  bubbleAnim: {
    "alpha": {
      "start": 1,
      "end": 1
    },
    "scale": {
      "start": 0.25,
      "end": 0.5,
      "minimumScaleMultiplier":0.5
    },
    "color": {
      "start": "ffffff",
      "end": "ffffff"
    },
    "speed": {
      "start": 150,
      "end": 150
    },
    "startRotation": {
      "min": 260,
      "max": 280
    },
    "rotationSpeed": {
      "min": 0,
      "max": 50
    },
    "lifetime": {
      "min": 2,
      "max": 8
    },
    "blendMode": "normal",
    "frequency": 0.016,
    "emitterLifetime": 0,
    "maxParticles": 500,
    "pos": {
      "x": 0,
      "y": 0
    },
    "addAtBack": false,
    "spawnType": "rect",
    "spawnRect": {
      "x": -450,
      "y": 200,
      "w": 900,
      "h": 0
    }
  },
  rain: {
    "alpha": {
      "start": 0.5,
      "end": 0.5
    },
    "scale": {
      "start": 0.5,
      "end": 1
    },
    "color": {
      "start": "ffffff",
      "end": "ffffff"
    },
    "speed": {
      "start": 1000,
      "end": 1000
    },
    "startRotation": {
      "min": 80,
      "max": 80
    },
    "rotationSpeed": {
      "min": 0,
      "max": 0
    },
    "lifetime": {
      "min": 1.2,
      "max": 1.2
    },
    "blendMode": "normal",
    "frequency": 0.004,
    "emitterLifetime": 0,
    "maxParticles": 500,
    "pos": {
      "x": 0,
      "y": 0
    },
    "addAtBack": false,
    "spawnType": "rect",
    "spawnRect": {
      "x": -600,
      "y": -760,
      "w": 900,
      "h": 20
    }
  },
  snow: {
    "alpha": {
      "start": 0.73,
      "end": 0.46
    },
    "scale": {
      "start": 0.2,
      "end": 0.36,
      "minimumScaleMultiplier":0.5
    },
    "color": {
      "start": "ffffff",
      "end": "ffffff"
    },
    "speed": {
      "start": 200,
      "end": 200
    },
    "startRotation": {
      "min": 60,
      "max": 70
    },
    "rotationSpeed": {
      "min": 0,
      "max": 200
    },
    "lifetime": {
      "min": 8,
      "max": 8
    },
    "blendMode": "normal",
    "ease": [
      {
        "s": 0,
        "cp": 0.379,
        "e": 0.548
      },
      {
        "s": 0.548,
        "cp": 0.717,
        "e": 0.676
      },
      {
        "s": 0.676,
        "cp": 0.635,
        "e": 1
      }
    ],
    "frequency": 0.01,
    "emitterLifetime": 0,
    "maxParticles": 1000,
    "pos": {
      "x": 0,
      "y": 0
    },
    "addAtBack": false,
    "spawnType": "rect",
    "spawnRect": {
      "x": -800,
      "y": -900,
      "w": 1200,
      "h": 20
    }
  },
  gas: {
    "alpha": {
      "start": 0.4,
      "end": 0
    },
    "scale": {
      "start": 2,
      "end": 0.4
    },
    "color": {
      "start": "6bff61",
      "end": "d8ff4a"
    },
    "speed": {
      "start": 10,
      "end": 10
    },
    "startRotation": {
      "min": 0,
      "max": 360
    },
    "rotationSpeed": {
      "min": 0,
      "max": 0
    },
    "lifetime": {
      "min": 2,
      "max": 1.8
    },
    "blendMode": "screen",
    "frequency": 0.01,
    "emitterLifetime": 0,
    "maxParticles": 1000,
    "pos": {
      "x": 0.5,
      "y": 0.5
    },
    "addAtBack": true,
    "spawnType": "circle",
    "spawnCircle": {
      "x": 0,
      "y": 0,
      "r": 150
    }
  }
}